package com.es.service;

import org.elasticsearch.action.search.SearchResponse;
import org.elasticsearch.index.query.Operator;

/**
 * @Author 咕唧
 * @Date 2022/6/22 19:15
 * @Version 1.0
 */
public interface QueryService {

    SearchResponse termQuery(String index, String field, String value) throws Exception;

    SearchResponse termsQuery(String index, String field, String... value) throws Exception;

    SearchResponse matchAllQuery(String index) throws Exception;

    SearchResponse matchQuery(String index, String field, String value) throws Exception;

    SearchResponse boolQuery(String index, String field, String value, Operator operator) throws Exception;

    SearchResponse multiMatch(String index, String value, String... field) throws Exception;
}
